import React, {useState, useEffect} from'react';
import { useLocation } from'react-router-dom';
import { NavBar, Button, Toast, Rate } from 'antd-mobile';
import { useNavigate } from'react-router-dom';
import styles from '../../css/Wyx/pingjia.module.css' 
import axios from 'axios'

// 任务详情页面
function PingJia() {
    const navigate = useNavigate();
    const location = useLocation();
 
     // 点击返回历史任务页面
    const back = () => {
        navigate('/lishi')
    }
    
    return (
        <div className={styles.ping}>
            <NavBar onBack={back} style={{backgroundColor: "#6a7d8f", color: "white", height: "6rem"}}>测量评价</NavBar>
            <div style={{display: "flex", alignItems: "center", height: "10rem", marginLeft: "1rem"}}>
                <img src="/imgs/18.png" alt="" style={{width: "5rem", height: "5rem", borderRadius: "50%"}} />
                <div style={{marginLeft: "1rem", fontSize: "1.6rem"}}>谭波波</div>
            </div>
            <div style={{height: "1.5rem", backgroundColor: "#f2f2f2"}}></div>

            <p style={{display: "flex", justifyContent: "center", alignItems: "center", height: "5rem"}}>设计师的评价</p>
            <div style={{display: "flex", justifyContent: "center", alignItems: "center", height: "5rem"}}>
                <Rate onChange={val => Toast.show(val.toString())} defaultValue={3} style={{"--active-color": "gray"}}/>       
            </div>

            <div>
                <p style={{marginLeft: "1rem"}}>评价内容</p>
                <div style={{marginLeft: "1rem", border: "1px solid #f2f2f2", height: "10rem", padding: "1rem"}}>
                    非常满意，服务态度好，非常感谢！
                </div>
            </div>
 
        </div>
    )
}

export default PingJia;